package com.smalluz.ad.modules.oe.result;

import com.fasterxml.jackson.annotation.JsonProperty;
import com.smalluz.ad.modules.common.result.BaseResult;
import com.smalluz.ad.modules.common.util.json.JacksonUtils;
import com.smalluz.ad.modules.oe.result.advertiser.AdvertiserResultInfo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.experimental.SuperBuilder;

@Data
@EqualsAndHashCode(callSuper=false)
@AllArgsConstructor
@NoArgsConstructor
@SuperBuilder
public class Oauth2AdvertiserResult extends BaseResult {
 
    private static final long serialVersionUID = 4122234863221206344L;
    
    @JsonProperty("data")
    private AdvertiserResultInfo data;
    
    public static Oauth2AdvertiserResult fromJson(String json) {
        return JacksonUtils.jsn2bean(json, Oauth2AdvertiserResult.class);
    }
}
